package com.szp.lagou.mq.rocketmq;

import com.szp.lagou.mq.rocketmq.properties.SecKillTimeProperties;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;

import javax.swing.*;

@SpringBootApplication
public class Application {
    public static void main(String[] args) {
        ConfigurableApplicationContext context  = SpringApplication.run(Application.class, args);
        SecKillTimeProperties secKillTimeProperties = context.getBean(SecKillTimeProperties.class);
        System.out.println(secKillTimeProperties.getDuration());
        System.out.println(secKillTimeProperties.getStartTime());
    }
}
